/*
 *    Copyright (c) 2018-2025, boss All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the boss developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: boss
 */

package com.hopes.bizz.risk.integral.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hopes.bizz.risk.common.constant.enums.RiskIntegralDicEnum;
import com.hopes.boss.admin.api.resolver.DictResolver;
import com.hopes.boss.admin.api.resolver.enums.AdminDictEnum;
import com.hopes.boss.common.entity.BaseLogicEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * 积分兑换审核记录
 *
 * @author pig
 * @date 2023-08-03 09:49:44
 */
@Data
@TableName("risk_integral_exchange_audit_record")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "积分兑换审核记录")
public class RiskIntegralExchangeAuditRecordEntity extends BaseLogicEntity {

    private static final long serialVersionUID = 1L;


	/**
	* 标识
	*/
    @TableId(type = IdType.ASSIGN_ID)
    @Schema(description="标识")
    private Long id;

	/**
	* 兑换Id
	*/
    @Schema(description="兑换Id")
    private Long exchangeId;

	/**
	* 节点步骤名称
	*/
    @Schema(description="节点步骤名称")
    private Integer stepsName;

	/**
	* 候选执行人
	*/
    @Schema(description="候选执行人")
    private String executorIds;

    /**
     * 处理人
     */
    @Schema(description="处理人")
    private Long handleUser;

	/**
	* 处理时间
	*/
    @Schema(description="处理时间")
    private Date handleTime;

	/**
	* 处理结论
	*/
    @Schema(description="处理结论")
    private Integer conclusion;

    /**
     * 意见
     */
    @Schema(description="意见")
    private String opinion;

	/**
	* 机构ID
	*/
    @Schema(description="机构ID")
    private Long orgId;

    public String getExecutorIdsStr() {
        return DictResolver.getItemLabelByValue(AdminDictEnum.sys_user, this.executorIds);
    }

    public String getConclusionStr() {
        return DictResolver.getItemLabelByValue(RiskIntegralDicEnum.handle_conclusion, this.conclusion);
    }

    public String getStepsNameStr() {
        return DictResolver.getItemLabelByValue(RiskIntegralDicEnum.integral_goods_audit_status, this.stepsName);
    }


}
